package com.eduhzy.ttw.work.mvp.model;

import com.eduhzy.ttw.commonsdk.entity.CommonData;
import com.eduhzy.ttw.work.mvp.contract.WorkUnSubmitContract;
import com.eduhzy.ttw.work.mvp.model.api.service.WorkApi;
import com.eduhzy.ttw.work.mvp.model.entity.WorkClassData;
import com.jess.arms.di.scope.FragmentScope;
import com.jess.arms.integration.IRepositoryManager;
import com.jess.arms.mvp.BaseModel;

import java.util.List;
import java.util.Map;

import javax.inject.Inject;

import io.reactivex.Observable;

/**
 * @author xubo
 * @date 2018-12-3 18:47:28
 */
@FragmentScope
public class WorkUnSubmitModel extends BaseModel implements WorkUnSubmitContract.Model {


    @Inject
    public WorkUnSubmitModel(IRepositoryManager repositoryManager) {
        super(repositoryManager);
    }

    @Override
    public Observable<CommonData<List<WorkClassData>>> workRecordList4Teacher(Map<String, Object> map) {
        return mRepositoryManager.obtainRetrofitService(WorkApi.class).workRecordList4Teacher(map);
    }
}